package com.kakarote.ids.provider.entity.BO;

import javax.validation.constraints.NotEmpty;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

@ApiModel("获取tokenBO")
public class GetTokenBO {
	@ApiModelProperty("clientId")
	@NotEmpty(message = "clientId 不能为空")
	private String clientId;
	@ApiModelProperty("clientSecret")
	@NotEmpty(message = "clientSecret 不能为空")
	private String clientSecret;
	@ApiModelProperty("重定向地址")
	@NotEmpty(message = "redirectUri 不能为空")
	private String redirectUri;

	public void setClientId(String clientId) {
		this.clientId = clientId;
	}

	@ApiModelProperty("grant_type")
	private String grantType;
	@ApiModelProperty("refreshToken")
	private String refreshToken;
	@ApiModelProperty("认证code")
	private String code;

	public void setClientSecret(String clientSecret) {
		this.clientSecret = clientSecret;
	}

	public void setRedirectUri(String redirectUri) {
		this.redirectUri = redirectUri;
	}

	public void setGrantType(String grantType) {
		this.grantType = grantType;
	}

	public void setRefreshToken(String refreshToken) {
		this.refreshToken = refreshToken;
	}

	public void setCode(String code) {
		this.code = code;
	}

	public boolean equals(Object o) {
		if (o == this)
			return true;
		if (!(o instanceof GetTokenBO))
			return false;
		GetTokenBO other = (GetTokenBO) o;
		if (!other.canEqual(this))
			return false;
		Object this$clientId = getClientId(), other$clientId = other.getClientId();
		if ((this$clientId == null) ? (other$clientId != null) : !this$clientId.equals(other$clientId))
			return false;
		Object this$clientSecret = getClientSecret(), other$clientSecret = other.getClientSecret();
		if ((this$clientSecret == null) ? (other$clientSecret != null) : !this$clientSecret.equals(other$clientSecret))
			return false;
		Object this$redirectUri = getRedirectUri(), other$redirectUri = other.getRedirectUri();
		if ((this$redirectUri == null) ? (other$redirectUri != null) : !this$redirectUri.equals(other$redirectUri))
			return false;
		Object this$grantType = getGrantType(), other$grantType = other.getGrantType();
		if ((this$grantType == null) ? (other$grantType != null) : !this$grantType.equals(other$grantType))
			return false;
		Object this$refreshToken = getRefreshToken(), other$refreshToken = other.getRefreshToken();
		if ((this$refreshToken == null) ? (other$refreshToken != null) : !this$refreshToken.equals(other$refreshToken))
			return false;
		Object this$code = getCode(), other$code = other.getCode();
		return !((this$code == null) ? (other$code != null) : !this$code.equals(other$code));
	}

	protected boolean canEqual(Object other) {
		return other instanceof GetTokenBO;
	}

	public int hashCode() {
		int PRIME = 59;
		int result = 1;
		Object $clientId = getClientId();
		result = result * 59 + (($clientId == null) ? 43 : $clientId.hashCode());
		Object $clientSecret = getClientSecret();
		result = result * 59 + (($clientSecret == null) ? 43 : $clientSecret.hashCode());
		Object $redirectUri = getRedirectUri();
		result = result * 59 + (($redirectUri == null) ? 43 : $redirectUri.hashCode());
		Object $grantType = getGrantType();
		result = result * 59 + (($grantType == null) ? 43 : $grantType.hashCode());
		Object $refreshToken = getRefreshToken();
		result = result * 59 + (($refreshToken == null) ? 43 : $refreshToken.hashCode());
		Object $code = getCode();
		return result * 59 + (($code == null) ? 43 : $code.hashCode());
	}

	public String toString() {
		return "GetTokenBO(clientId=" + getClientId() + ", clientSecret=" + getClientSecret() + ", redirectUri="
				+ getRedirectUri() + ", grantType=" + getGrantType() + ", refreshToken=" + getRefreshToken() + ", code="
				+ getCode() + ")";
	}

	public String getClientId() {
		return this.clientId;
	}

	public String getClientSecret() {
		return this.clientSecret;
	}

	public String getRedirectUri() {
		return this.redirectUri;
	}

	public String getGrantType() {
		return this.grantType;
	}

	public String getRefreshToken() {
		return this.refreshToken;
	}

	public String getCode() {
		return this.code;
	}
}
